package com.talent.web.mqtt;

import com.talent.web.mqtt.handler.MqttGateway;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author watson
 * @Description"
 * @date: 2025/1/8 21:20
 */

/**
 * @Author: hszhou
 * @Date: 2025/1/8 21:15
 * @Description: 必须描述类做什么事情, 实现什么功能
 */
@Service
public class MqttMessageSender {

    @Autowired
    private MqttGateway mqttGateway;

    public void  send(String topic,String message){
        mqttGateway.sendToMqtt(topic,message);
    }

    public void  send(String topic,int qos,String message){
        mqttGateway.sendToMqtt(topic,qos,message);
    }
}
